/********************************************************************
	created:	2008/06/17
	created:	17:6:2008   14:31
	filename: 	SkinStatic.h
	author:		Dean
	
	purpose:	
*********************************************************************/
#pragma once

#include "SkinControl.h"

// CSkinStatic

class CSkinStatic : public CStatic, public CSkinControl
{
	DECLARE_DYNAMIC(CSkinStatic)

public:
	CSkinStatic();
	virtual ~CSkinStatic();

	void SetFont(LPCTSTR fontFamily, INT size, INT style);
	void SetFontColor(COLORREF val) { m_clFnt = val; }
	void SetSize(INT cx, INT cy);
protected:
	// CSkinControl
	virtual BOOL CreateInternal(const RECT& rect, CWnd* pParentWnd, UINT nID) ;
	virtual BOOL LoadSkinImage(LPCTSTR lpszFilename) ;
	virtual void DrawIt (Gdiplus::Bitmap* pbmWnd, const RECT& rect) ;
	virtual CRect GetPlacement(const INT cxFrame, const INT cyFrame);

	virtual void DrawItem(LPDRAWITEMSTRUCT /*lpDrawItemStruct*/){
		UpdateSkin();
	}
protected:
	DECLARE_MESSAGE_MAP()
protected:
	CSize					m_sizeControl;
	CAutoPtr<Gdiplus::Font>	m_pFont;
	COLORREF				m_clFnt;	
};


